Conversation
Add fairy feature flags and invite system: - Feature flag system (fairies_enabled, fairies_purchase_enabled) with admin UI - Update pricing page with Paddle payment integration - Fairy invite flow should work for signed out users, redirects them after sign in - Redirect to home when fairy flags disabled - Admin page for toggling feature flags - Extract payment logic from sidebar to reusable usePaddle hook - Add descriptions and reddemedby to fairy invites. ### Change type - [x] `other` <!-- CURSOR_SUMMARY --> --- > [!NOTE] > Adds KV-backed feature flags (fairies, fairies_purchase) with admin controls, gates UI/DO/routes, enhances fairy invites (description/redeemedBy, signed-out flow), and centralizes Paddle checkout used on pricing and sidebar. > > - **Feature Flags (global)**: > - Add KV-backed flags `fairies` and `fairies_purchase` with `/app/feature-flags` API and polling `FeatureFlagsFetcher` + `useFeatureFlags`. > - Gate client hooks (`useFairyAccess`), UI (sidebar/purchase/pricing), and DO `/fairy/has-access` + invite redemption by flags. > - **Checkout / Pricing**: > - Extract Paddle integration to `usePaddle` and use in pricing page and sidebar link. > - Pricing page: sign-in redirect (`redirect-to`), conditional button labels, deep-link checkout via `?checkout=true`. > - **Fairy Invites**: > - Add `description` and `redeemedBy` tracking (DB migration) and show in Admin table; include description on create. > - Signed-out invite flow stores token and triggers sign-in, then processes via root handler. > - **Admin**: > - New Feature Flags section (toggle flags) and updated Fairy Invites management (grant/remove access unified, description input, copy link). > - **Backend/Worker**: > - New feature flag utils (get/set, defaults by env), admin routes for flags, worker route exposure, KV bindings in wrangler. > - **i18n/UI**: > - Add strings for “Home”, “Start your fairy adventure”, “Your fairies are waiting for you! →”. > > <sup>Written by [Cursor Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit bc78b6f. This will update automatically on new commits. Configure [here](https://cursor.com/dashboard?tab=bugbot).</sup> <!-- /CURSOR_SUMMARY -->
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )